import request from '@/utils/request'

// 查询应收核销单列表
export function listReceiveReconciliation(query) {
  return request({
    url: '/finance/receiveReconciliation/list',
    method: 'get',
    params: query
  })
}
export function getAllCus() {
  return request({
    url: '/basedata/customer/getAllCus',
    method: 'get',
  })
}
export function getReciveList(reciveReq) {
  return request({
    url: '/finance/reciveReq/list',
    method: 'get',
    params: reciveReq
  })
}
export function getReciveOrderList(reciveOrder) {
  return request({
    url: '/finance/reciveOrder/list',
    method: 'get',
    params: reciveOrder
  })
}

// 查询应收核销单详细
export function getReceiveReconciliation(id) {
  return request({
    url: '/finance/receiveReconciliation/' + id,
    method: 'get'
  })
}

// 新增应收核销单
export function addReceiveReconciliation(data) {
  return request({
    url: '/finance/receiveReconciliation',
    method: 'post',
    data: data
  })
}

// 修改应收核销单
export function approval(approvalDto) {
  return request({
    url: '/finance/receiveReconciliation/approval',
    method: 'post',
    data: approvalDto
  })
}

// 删除应收核销单
export function delReceiveReconciliation(id) {
  return request({
    url: '/finance/receiveReconciliation/' + id,
    method: 'delete'
  })
}
